Enumeration of Words in Context-free Languages Using Haskell

نویسندگان

  • Wojciech WIECZOREK
  • W. Wieczorek
چکیده

Streszczenie. Jednym z rozważanych problemów kombinatorycznych jest wyliczenie w porządku leksykograficznym wszystkich słów o długości n należących do pewnego języka L. W niniejszym artykule zaprezentowano algorytm – wraz ze stosownym kodem w języku Haskell – służący do takiego wyliczania. Zakładamy, że język L zdefiniowany jest za pomocą gramatyki bezkontekstowej bez produkcji jednostkowych i bez λ-produkcji. Słowa kluczowe: język formalny bezkontekstowy, wyliczanie, Haskell, kolejność alfabetyczna

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

On Lexicographic Enumeration of Regular and Context-Free Languages

We show that it is possible to e ciently enumerate the words of a regular language in lexicographic order. The time needed for generating the next word is O(n) when enumerating words of length n. We also de ne a class of context-free languages for which e cient enumeration is possible.

متن کامل

Enumeration of Context-Free Languages and Related Structures

In this paper, we consider the enumeration of context-free languages. In particular, for any reasonable descriptional complexity measure for context-free grammars, we demonstrate that the exact quantity of context-free languages of size is uncomputable. Nevertheless, we are able to give upper and lower bounds on the number of such languages. We also generalize our results to enumerate predicate...

متن کامل

Studying impressive parameters on the performance of Persian probabilistic context free grammar parser

In linguistics, a tree bank is a parsed text corpus that annotates syntactic or semantic sentence structure. The exploitation of tree bank data has been important ever since the first large-scale tree bank, The Penn Treebank, was published. However, although originating in computational linguistics, the value of tree bank is becoming more widely appreciated in linguistics research as a whole. F...

متن کامل

T F L T C E  F L

We survey recent results on the enumeration of formal languages. In particular, we consider enumeration of regular languages accepted by deterministic and nondeterministic finite automata with n states, regular languages generated by regular expressions of a fixed length, and ω-regular languages accepted by Müller automata. We also survey the uncomputability of enumeration of context-free langu...

متن کامل

HASDF: A Generalized LR-parser Generator for Haskell

Language-centered software engineering requires language technology that (i) handles the full class of context-free grammars, and (ii) accepts grammars that contain syntactic information only. The syntax definition formalism SDF combined with GLR-parser generation offers such technology. We propose to make SDF and GLR-parsing available for use with various programming languages. We have done so...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

عنوان ژورنال:

دوره   شماره 

صفحات  -

تاریخ انتشار 2017